package com.suzhe.ymall.order.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.suzhe.ymall.order.mapper.ShippingAddressMapper;
import com.suzhe.ymall.order.pojo.ShippingAddress;
import com.suzhe.ymall.order.service.IShippingAddressService;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * <p>
 * 发货地址 服务实现类
 * </p>
 *
 * @author suzhe
 * @since 2019-08-08
 */
@Service
public class ShippingAddressServiceImpl extends ServiceImpl<ShippingAddressMapper, ShippingAddress> implements IShippingAddressService {

    @Override
    public List<ShippingAddress> getByUserId(Integer userId) {

        return list(new QueryWrapper<ShippingAddress>().eq("user_id",userId));
    }
}
